﻿/***************************************************************************
                          qgsabout.cpp  -  description
                             -------------------
    begin                : Sat Aug 10 2002
    copyright            : (C) 2002 by Gary E.Sherman
    email                : sherman at mrcc.com
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#include "qgsabout.h"
#include "qgsapplication.h"
#include "qgsauthmethodregistry.h"
#include "qgsproviderregistry.h"
#include "qgslogger.h"
#include <QDesktopServices>
#include <QFile>
#include <QTextStream>
#include <QImageReader>
#include <QSqlDatabase>
#include <QTcpSocket>

QgsAbout::QgsAbout( QWidget * parent )
    : QgsOptionsDialogBase( QStringLiteral( "about" ), parent )  // Normal dialog in non Mac-OS
{
    setupUi( this );
    initOptionsBase( true, QStringLiteral( "%1 - %2 Bit" ).arg( windowTitle() ).arg( QSysInfo::WordSize ) );
    init();
}

void QgsAbout::init()
{
    // set the 60x60 icon pixmap
    qgisIcon->setPixmap( QPixmap( "qrc:/images/myImages/appIcon.png" ) );
}

void QgsAbout::setVersion( const QString &v )
{
    txtVersion->setBackgroundRole( QPalette::NoRole );
    txtVersion->setAutoFillBackground( true );
    txtVersion->setHtml(v);
}

